<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
    <!-- 最新版本的 Bootstrap 核心 CSS 文件 -->
    <link
      rel="stylesheet"
      href="https://stackpath.bootstrapcdn.com/bootstrap/3.4.1/css/bootstrap.min.css"
      integrity="sha384-HSMxcRTRxnN+Bdg0JdbxYKrThecOKuH5zCYotlSAcp1+c8xmyTe9GYg1l9a69psu"
      crossorigin="anonymous"
    />
    <style>
      .content {
        height: 300px;
        background-color: lightblue;
        margin: 10px 0;
      }

      .content-child {
        height: 200px;
        background-color: orange;
      }
    </style>
  </head>
  <body>
    <!-- container是固定宽度 -->
    <div class="container">
      <div class="row">
          <div class="col-sm-6 col-md-4"> 

            <!-- 栅格系统 是支持嵌套的 -->
            <div class="container-fluid">
              <div class="row">
                <div class="col-xs-4"><div class="content-child"></div></div>
                <div class="col-xs-4"><div class="content-child"></div></div>
                <div class="col-xs-4"><div class="content-child"></div></div>
              </div>
            </div>

          </div>
          <div class="col-sm-6 col-md-4"> <div class="content"></div></div>
          <div class="col-sm-6 col-md-4"> <div class="content"></div></div>
          <div class="col-sm-6 col-md-4"> <div class="content"></div></div>
          <div class="col-sm-6 col-md-4"> <div class="content"></div></div>
          <div class="col-sm-6 col-md-4"> <div class="content"></div></div>
      </div>
     
    </div>
    
    <!-- 百分百宽度 -->
    <div class="container-fluid">
      <div class="row">
          <div class="col-md-4"> <div class="content"></div></div>
          <div class="col-md-4"> <div class="content"></div></div>
          <div class="col-md-4"> <div class="content"></div></div>
          <div class="col-md-4"> <div class="content"></div></div>
          <div class="col-md-4"> <div class="content"></div></div>

      </div>
    </div>

    <!-- 列偏移 -->
    <div class="container">
      <div class="row">
        <div class="col-md-4"><div class="content"></div></div>
        <div class="col-md-4 col-md-offset-4"><div class="content">.col-md-4 .col-md-offset-4</div></div>
      </div>
      <div class="row">
        <div class="col-md-3 col-md-offset-3"><div class="content"></div>.col-md-3 .col-md-offset-3</div></div>
        <div class="col-md-3 col-md-offset-3"><div class="content"></div>.col-md-3 .col-md-offset-3</div></div>
      </div>
      <div class="row">
        <div class="col-md-6 col-md-offset-3"><div class="content"></div>.col-md-6 .col-md-offset-3</div></div>
      </div>
    </div>


    <!-- 列排序 -->
    <div class="container">
      <div class="row">
        <div class="col-md-9"><div class="content">.col-md-9</div></div>
        <div class="col-md-3"><div class="content">.col-md-3 </div></div>
      </div>
        <div class="row">
          <div class="col-md-9 col-md-push-3"><div class="content">.col-md-9 .col-md-push-3</div></div>
          <div class="col-md-3 col-md-pull-9"><div class="content">.col-md-3 .col-md-pull-9</div></div>
  
      </div>
    </div>

    <script src="https://cdn.bootcdn.net/ajax/libs/jquery/3.6.0/jquery.min.js"></script>
    <!-- 最新的 Bootstrap 核心 JavaScript 文件 -->
    <!-- bootstrap中的js文件 依赖于jquery 所以必须在之前放一个jquery的js文件 -->
    <script
      src="https://stackpath.bootstrapcdn.com/bootstrap/3.4.1/js/bootstrap.min.js"
      integrity="sha384-aJ21OjlMXNL5UyIl/XNwTMqvzeRMZH2w8c5cRVpzpU8Y5bApTppSuUkhZXN0VxHd"
      crossorigin="anonymous"
    ></script>
  </body>
</html>
